package com.tianyang.yukuaifuzs.business.main.adapter;

import androidx.annotation.NonNull;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.tianyang.yukuaifuzs.R;
import com.tianyang.yukuaifuzs.business.main.bean.DeviceOutput;
import com.tianyang.yukuaifuzs.utils.VerifyUtil;

import java.util.ArrayList;

/**
 * Description：
 * Created by xyj on 2024/4/24
 */
public class ChooseSoundAdapter extends BaseQuickAdapter<DeviceOutput, BaseViewHolder> {

    public ChooseSoundAdapter() {
        super(R.layout.item_choose_sound, new ArrayList<>());
    }

    @Override
    protected void convert(@NonNull BaseViewHolder helper, DeviceOutput item) {
        if (item != null) {
            helper.setText(R.id.posNameTv, VerifyUtil.checkString(item.getPosName()))
                    .setText(R.id.posModelTv, "设备类型："+VerifyUtil.checkString(item.getPosModel()))
                    .setText(R.id.posNumberTv, "SN："+VerifyUtil.checkString(item.getPosNumber()));
        }
    }
}
